home *** CD-ROM | disk | FTP | other *** search
/ Workbench Add-On / Workbench Add-On - Volume 1.iso / Gfx / Edit / TSMorph / src / Install < prev    next >
Text File  |  1995-03-12  |  8KB  |  357 lines

  1. ; TSMorph - Amiga Morphing program
  2. ; Copyright (C) © 1993/94 Topicsave Limited
  3.  
  4. ; This program is free software; you can redistribute it and/or modify
  5. ; it under the terms of the GNU General Public License as published by
  6. ; the Free Software Foundation; either version 2 of the License, or
  7. ; any later version.
  8.  
  9. ; This program is distributed in the hope that it will be useful,
  10. ; but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. ; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  12. ; GNU General Public License for more details.
  13.  
  14. ; You should have received a copy of the GNU General Public License
  15. ; along with this program; if not, write to the Free Software
  16. ; Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  17.  
  18. ; mpaddock@cix.compulink.co.uk
  19.  
  20. ; This is the script to install TSMorph
  21. ; $VER: TSMorph-Install 3.2 (12.3.95)
  22.  
  23. (complete 0)
  24.  
  25. (set InstallDir
  26.    (askdir
  27.       (prompt "Where do you want to install TSMorph 3.2")
  28.       (help @askdir-help)
  29.       (default "Work:")
  30.    )
  31. )
  32.  
  33. (if (> (/ (getversion) 65536) 38)
  34.    (set Kick30 1)
  35.    (set Kick30 0)
  36. )
  37.  
  38. (Set DestDir 
  39.    (tackon InstallDir "TSMorph")
  40. )
  41.  
  42. (Set RexxDir 
  43.    (tackon DestDir "Rexx")
  44. )
  45.  
  46. (Set CursorDir 
  47.    (tackon DestDir "Cursor")
  48. )
  49.  
  50. (Set BrushDir 
  51.    (tackon DestDir "Brush")
  52. )
  53.  
  54. (Set TutDir 
  55.    (tackon DestDir "Tutorial")
  56. )
  57.  
  58. (Set HTMLDir 
  59.    (tackon DestDir "HTML")
  60. )
  61.  
  62. (set @default-dest 
  63.    DestDir
  64. )
  65.  
  66. (makedir
  67.    DestDir 
  68.    (infos)
  69. )
  70.  
  71. (Set Use040
  72.    (= 
  73.       (database "cpu")
  74.       68040
  75.    )
  76. )
  77.  
  78. (Set Has881
  79.     (+
  80.         (AND
  81.             (NOT (run "cpu check 68881"))
  82.            (>=
  83.               (database "cpu")
  84.               68020
  85.            )
  86.        )
  87.        Use040
  88.     )
  89. )
  90.  
  91. (set Use881
  92.    (askchoice
  93.       (prompt "Install which version?")
  94.       (help "There are three versions of the TSMorph-render program. "
  95.             "One should run on any processor. "
  96.             "One requires both a 68020 or 68030 CPU with a 68881 or 68882 FPU. "
  97.             "The other requires a 68040.")
  98.       (choices
  99.          "No FPU version"
  100.          "68020/030/68881/2"
  101.          "68040"
  102.       )
  103.       (default Has881)
  104.    )
  105. )
  106.  
  107. (complete 10)
  108.  
  109. (if (> Use881 1)
  110.  (
  111.    (copyfiles
  112.       (prompt "Copying TSMorph program and data files")
  113.       (help @copyfiles-help)
  114.       (source "")
  115.       (dest DestDir)
  116.       (choices "TSMorph" "TSMorph-render.040" "TSMorph.doc" "TSMorph.guide" "TSMorph-prefs")
  117.       (infos)
  118.       (confirm)
  119.    )
  120.    (delete (tackon DestDir "TSMorph-render"))
  121.    (rename (tackon DestDir "TSMorph-render.040")
  122.            (tackon DestDir "TSMorph-render")
  123.    )
  124.    (delete (tackon DestDir "TSMorph-render.info"))
  125.    (rename (tackon DestDir "TSMorph-render.040.info")
  126.            (tackon DestDir "TSMorph-render.info")
  127.    )
  128.  )
  129. )
  130.  
  131. (if (= Use881 1)
  132.  (
  133.    (copyfiles
  134.       (prompt "Copying TSMorph program and data files")
  135.       (help @copyfiles-help)
  136.       (source "")
  137.       (dest DestDir)
  138.       (choices "TSMorph" "TSMorph-render.881" "TSMorph.doc" "TSMorph.guide" "TSMorph-prefs")
  139.       (infos)
  140.       (confirm)
  141.    )
  142.    (delete (tackon DestDir "TSMorph-render"))
  143.    (rename (tackon DestDir "TSMorph-render.881")
  144.            (tackon DestDir "TSMorph-render")
  145.    )
  146.    (delete (tackon DestDir "TSMorph-render.info"))
  147.    (rename (tackon DestDir "TSMorph-render.881.info")
  148.            (tackon DestDir "TSMorph-render.info")
  149.    )
  150.  )
  151. )
  152.  
  153. (if (= Use881 0)
  154.  (
  155.    (copyfiles
  156.       (prompt "Copying TSMorph program and data files")
  157.       (help @copyfiles-help)
  158.       (source "")
  159.       (dest DestDir)
  160.       (choices "TSMorph" "TSMorph-render" "TSMorph.doc" "TSMorph.guide" "TSMorph-prefs")
  161.       (infos)
  162.       (confirm)
  163.    )
  164.  )
  165. )
  166.  
  167. (if Kick30
  168.    (tooltype
  169.       (dest (tackon destdir "TSMorph.guide"))
  170.       (setdefaulttool "MultiView")
  171.    )
  172. )
  173.  
  174. (complete 20)
  175.  
  176. (makedir
  177.    RexxDir
  178.    (infos)
  179. )
  180.  
  181. (copyfiles
  182.    (prompt "Copying example Rexx scripts")
  183.    (help @copyfiles-help)
  184.    (source "Rexx")
  185.    (dest RexxDir)
  186.    (all)
  187.    (infos)
  188.    (confirm)
  189. )
  190.  
  191. (complete 30)
  192.  
  193. (makedir "ENVARC:TSMorph")
  194.  
  195. (copyfiles
  196.    (prompt "Copying Icons to ENVARC:")
  197.    (help @copyfiles-help)
  198.    (source "")
  199.    (dest "ENVARC:TSmorph")
  200.    (choices "ENV/TSMorph/def_points.info"
  201.             "ENV/TSMorph/def_bw16.info"
  202.             "ENV/TSMorph/def_bw256.info"
  203.             "ENV/TSMorph/def_dctv3.info"
  204.             "ENV/TSMorph/def_dctv4.info"
  205.             "ENV/TSMorph/def_ham6.info"
  206.             "ENV/TSMorph/def_ham8.info"
  207.             "ENV/TSMorph/def_iff.info"
  208.             "ENV/TSMorph/def_ilbm.info"
  209.             "ENV/TSMorph/def_jpg.info"
  210.             "ENV/TSMorph/def_ppm.info"
  211.             "ENV/TSMorph/def_prefs.info")
  212.    (confirm)
  213. )
  214.  
  215. (complete 40)
  216.  
  217. (makedir "ENV:TSMorph")
  218.  
  219. (copyfiles
  220.    (prompt "Copying Icons to ENV:")
  221.    (help @copyfiles-help)
  222.    (source "")
  223.    (dest "ENV:TSmorph")
  224.    (choices "ENV/TSMorph/def_points.info"
  225.             "ENV/TSMorph/def_bw16.info"
  226.             "ENV/TSMorph/def_bw256.info"
  227.             "ENV/TSMorph/def_dctv3.info"
  228.             "ENV/TSMorph/def_dctv4.info"
  229.             "ENV/TSMorph/def_ham6.info"
  230.             "ENV/TSMorph/def_ham8.info"
  231.             "ENV/TSMorph/def_iff.info"
  232.             "ENV/TSMorph/def_ilbm.info"
  233.             "ENV/TSMorph/def_jpg.info"
  234.             "ENV/TSMorph/def_ppm.info"
  235.             "ENV/TSMorph/def_prefs.info")
  236.    (confirm)
  237. )
  238.  
  239. (complete 50)
  240.  
  241. (if
  242.    (askbool
  243.       (prompt "Copy GUI files?")
  244.       (help "Select 'Yes' to copy the GUI files. "
  245.             "These files may then be changed to allow you to configure the user interface. "
  246.             "Select 'No' if you do not wish to change the interface.")
  247.       (default 0)
  248.    )
  249.    (
  250.       (makedir CursorDir)
  251.       (copyfiles
  252.          (prompt "Copying Pointer files")
  253.          (help @copyfiles-help)
  254.          (source "Cursor")
  255.          (dest CursorDir)
  256.          (all)
  257.          (infos)
  258.          (confirm)
  259.       )
  260.       (complete 55)
  261.       (makedir BrushDir)
  262.       (copyfiles
  263.          (prompt "Copying Gadget files")
  264.          (help @copyfiles-help)
  265.          (source "Brush")
  266.          (dest BrushDir)
  267.          (all)
  268.          (infos)
  269.          (confirm)
  270.       )
  271.    )
  272. )
  273.  
  274. (complete 60)
  275.  
  276. (if
  277.    (askbool
  278.       (prompt "Copy Tutorial files?")
  279.       (help "A short tutorial and some image files are included. "
  280.             "Select 'Yes' to copy the Tutorial files. "
  281.             "Select 'No' if you do not wish to install the Tutorial.")
  282.       (default 1)
  283.    )
  284.    (
  285.       (makedir TutDir)
  286.       (copyfiles
  287.          (prompt "Copying Tutorial files")
  288.          (help @copyfiles-help)
  289.          (source "Tutorial")
  290.          (dest TutDir)
  291.          (all)
  292.          (infos)
  293.          (confirm)
  294.       )
  295.    )
  296. )
  297.  
  298. (complete 70)
  299.  
  300. (if
  301.    (askbool
  302.       (prompt "Copy .html files?")
  303.       (help "Documentation is also included in .html format. "
  304.             "You will need Mosaic to read these files. "
  305.             "If you do not have Mosaic (or do not know what it is) then "
  306.             "you will not want to copy the files. "
  307.             "Select 'Yes' to copy the .html files. "
  308.             "Select 'No' if you do not wish to install the .html files.")
  309.       (default 0)
  310.    )
  311.    (
  312.       (makedir HTMLDir)
  313.       (copyfiles
  314.          (prompt "Copying .html files")
  315.          (help @copyfiles-help)
  316.          (source "HTML")
  317.          (dest HTMLDir)
  318.          (all)
  319.       )
  320.       (complete 75)
  321.       (copyfiles
  322.          (prompt "Copying View_HTML icon")
  323.          (help @copyfiles-help)
  324.           (source "")
  325.           (dest DestDir)
  326.          (choices "View_HTML.info")
  327.       )
  328.       (set Mosaic
  329.          (askfile
  330.             (prompt "Where is Mosaic?")
  331.             (help "The exact location and name of Mosaic is required "
  332.                   "to enable a script to be set up to view the documentation.")
  333.             (default "work:Mosaic")
  334.          )
  335.       )
  336.       (textfile
  337.           (dest (tackon DestDir "View_HTML"))
  338.           (append "cd HTML\n")
  339.           (append Mosaic " file://localhost/TSMorph:html/TSMorph.html")
  340.       )
  341.    )
  342. )
  343.  
  344. (complete 80)
  345.  
  346. (startup "TSMorph"
  347.    (prompt "Adding assign TSMorph: to " DestDir " in s:user-startup")
  348.    (help @startup-help)
  349.    (command "Assign TSMorph: " DestDir)
  350. )
  351.  
  352. (complete 90)
  353.  
  354. (makeassign "TSMorph" DestDir)
  355.  
  356. (complete 100)
  357.